Predicting a Correct Program in Programming By Example
ثبت نشده
چکیده
We study the problem of efficiently predicting a correct program from a large set of programs induced from few input-output examples in Programming-by-Example (PBE) systems. This is an important problem for making PBE systems usable so that users do not need to provide too many examples to learn the desired program. We first characterize the three main types of expressions used for expression sharing in domain-specific languages of versionspace algebra based PBE systems, namely Union expressions, Join expressions, and DAG expressions. We then present a supervised learning-to-rank approach for learning a hierarchical ranking function to efficiently predict a correct program. The key observation of our learning approach is that ranking any correct program over all incorrect programs is sufficient for generating the correct output on new inputs, which leads to a novel loss function in the gradient descent based learning algorithm. We also describe a technique for automatically generating the required labeled training data from benchmark tasks (specified using input-output examples). A key challenge in using any ranking methodology for expressions represented using version-space algebra based data structures is that of efficiency. We describe features and algorithms for efficiently identifying the highest ranked program amongst the expressions represented succinctly using different forms of sharing. We present the successful evaluation of our ranking technique for the FlashFill PBE system on over 175 string manipulation tasks obtained from Excel help forums. Our ranking technique works in real-time, reduces the average number of examples required for learning the desired transformation from 4.17 to 1.48, and learns the transformation from just one input-output example for 74% of the benchmark tasks.
منابع مشابه
Predicting a Correct Program in Programming by Example
We study the problem of efficiently predicting a correct program from a large set of programs induced from few input-output examples in Programming-byExample (PBE) systems. This is an important problem for making PBE systems usable so that users do not need to provide too many examples to learn the desired program. We first formalize the two classes of sharing that occurs in version-space algeb...
متن کاملModified FGP approach and MATLAB program for solving multi-level linear fractional programming problems
In this paper, we present modified fuzzy goal programming (FGP) approach and generalized MATLAB program for solving multi-level linear fractional programming problems (ML-LFPPs) based on with some major modifications in earlier FGP algorithms. In proposed modified FGP approach, solution preferences by the decision makers at each level are not considered and fuzzy goal for the decision vectors i...
متن کاملComputational and Programming Aspects of Transition Elements in a Three-dimensional Finite Element Program
The performance of any finite element (FE) structural analysis is directly related to the global number of nodes and degrees of freedom (DOF) of the discretized structure and mesh distribution attributes. It is obvious that the appropriate numerical analysis needs finer elements in the zone of interest, e.g. zone of high stress concentration and intensity, and coarser elements for farther porti...
متن کاملApplication of Gene Expression Programming and Support Vector Regression models to Modeling and Prediction Monthly precipitation
Estimating and predicting precipitation and achieving its runoff play an important role to correct management and exploitation of basins, management of dams and reservoirs, minimizing the flood damages and droughts, and water resource management, so they are considered by hydrologists. The appropriate performance of intelligent models leads researchers to use them for predicting hydrological ph...
متن کاملClose interval approximation of piecewise quadratic fuzzy numbers for fuzzy fractional program
The fuzzy approach has undergone a profound structural transformation in the past few decades. Numerous studies have been undertaken to explain fuzzy approach for linear and nonlinear programs. While, the findings in earlier studies have been conflicting, recent studies of competitive situations indicate that fractional programming problem has a positive impact on comparative scenario. We pro...
متن کامل